1. Field of the Invention
The present invention relates to a communication technique that makes it possible to avoid omission of communication data.
2. Description of the Related Art
The greater functionality of devices achieved in recent years has teen accompanied by the problem of increased internal wiring of such devices. For example, in a robot system such as that of an industrial robot, when the numbers of fingers, joints and sensors are increased in order to accommodate more complex operations, a problem which arises is a decline in assembly capability because the number of wiring interconnections increases and the wiring itself impedes operation. Accordingly, greater use is being made of network communication for transmission of information within the system in order to reduce the number of wiring interconnections. In a case where real-time control such as servo control is carried out in such a system, the general practice is to use cyclic communication based upon TDMA.
When servo control using TDMA-based cyclic communication is carried out, time slots within a frame are assigned to respective ones of a master device and multiple slave devices. In the time slot assigned to it, the master device transmits a servo instruction suet as a target angle to each slave device. The slave device is provided with a motor and an angle sensor such as an encoder. The slave device drives the motor based upon the servo instruction received from the master device, acquires the rotational angle of the motor from the angle sensor and calculates a deviation between the servo instruction and the actual angle. The slave device transmits the deviation to the master device in the assigned time slot. The master device generates the servo instruction of the next frame based upon the deviation transmitted from the slave device. Feedback control of the system is carried out by these operations.
In a case where generation of the servo instruction and calculation of the deviation are executed by software processing, a fluctuation in processing time arises and processing may not be completed by the assigned transmission time slot. In such case, a problem which arises is that, normal communication will not be achieved and both control precision and control stability will decline.
A technique described in the specification of Japanese Patent Laid-Open No. 2005-303534 is known as a technique for dealing with this problem. This technique puts transmission on hold in a case where the generation of transmission data as not completed, thereby assuring simultaneity of transmission data. With Japanese Patent Laid-Open No. 2005-303534, if the generation of transmission data is not completed, omission of communication data will occur in the applicable frame but, if control computations are halted at this time, a problem which arises is unstable operation. A technique described in the specification of Japanese Patent Laid-Open No. 2007-228462 for dealing with this problem generates a control-computation start signal if omission of communication data has occurred, thereby executing control computations in continuous fashion.
However, even if the techniques described in Japanese Patent Laid-Open No. 2005-303534 and Japanese Patent Laid-Open No. 2007-228462 are used, when processing for generating transmission data is not completed, omission of communication data occurs and control is carried out with the sending and receiving of the latest data remaining unexecuted in the applicable frame. Accordingly, in a case where processing is not completed by the assigned transmission time slot, the problem of diminished control precision and control stability remains unsolved. A conceivable method of avoiding this problem is to assign a time slot to each device upon assuring adequate processing time for generating the transmission data. However, although this method enables omission of communication data to be avoided, frame length, namely control cycle time, cannot be shortened. This makes it difficult to improve control precision and response.